<div class="fornecedores form">

	<div class="row">
		<div class="col-md-12">
			<div class="page-header">
				<h1><?php echo __('Editar Fornecedor'); ?></h1>
			</div>
		</div>
	</div>



	<div class="row">
		<div class="col-md-3">
			<div class="actions">
				<div class="panel panel-default">
					<div class="panel-heading">Actions</div>
						<div class="panel-body">
							<ul class="nav nav-pills nav-stacked">
								<li><?php echo $this->Form->postLink(__('<span class="glyphicon glyphicon-remove"></span>&nbsp;&nbsp;Delete'), array('action' => 'delete', $this->Form->value('Fornecedore.id')), array('escape' => false), __('Are you sure you want to delete # %s?', $this->Form->value('Fornecedore.id'))); ?></li>
								<li><?php echo $this->Html->link(__('<span class="glyphicon glyphicon-list"></span>&nbsp;&nbsp;List Fornecedores'), array('action' => 'index'), array('escape' => false)); ?></li>
								<li><?php //echo $this->Html->link(__('<span class="glyphicon glyphicon-list"></span>&nbsp;&nbsp;List Enderecos'), array('controller' => 'enderecos', 'action' => 'index'), array('escape' => false)); ?> </li>
								<li><?php //echo $this->Html->link(__('<span class="glyphicon glyphicon-plus"></span>&nbsp;&nbsp;New Endereco'), array('controller' => 'enderecos', 'action' => 'add'), array('escape' => false)); ?> </li>
							</ul>
						</div>
					</div>
				</div>			
		</div><!-- end col md 3 -->
		<div class="col-md-9">
			<?php echo $this->Form->create('Fornecedore', array('role' => 'form')); ?>
				<div class="panel panel-default">
					
					<div class="panel-body">
					<h3>Fornecedor</h3>
						<div class="form-group">
							<?php echo $this->Form->input('id', array('class' => 'form-control', 'placeholder' => 'Id'));?>
						</div>
						
						<div class="row">
							<div class="form-group col-md-6">
								<?php echo $this->Form->input('nome', array('class' => 'form-control', 'placeholder' => 'Nome da empresa'));?>
							</div>
							
							<div class="form-group col-md-6">
									<?php echo $this->Form->input('representante', array('class' => 'form-control', 'placeholder' => 'Representante comercial'));?>
							</div>
						</div>
						
						<div class = "row">
							<div class="form-group col-md-4">
								<?php echo $this->Form->input('cnpj', array('class' => 'form-control', 'placeholder' => 'Cnpj'));?>
							</div>
							<div class="form-group col-md-4">
								<?php echo $this->Form->input('telefone', array('class' => 'form-control', 'placeholder' => 'Telefone'));?>
							</div>
							<div class="form-group col-md-4">
								<?php echo $this->Form->input('email', array('class' => 'form-control', 'placeholder' => 'Email'));?>
							</div>
						</div>
						<div class="row">
							
							<div class="form-group col-md-6">
								<?php echo $this->Form->input('site', array('class' => 'form-control', 'placeholder' => 'Site'));?>
							</div>
							
							<div class="form-group col-md-6">
								<?php echo $this->Form->input('ramo_id', array('class' => 'form-control', 'placeholder' => 'Ramo Id'));?>
							</div>
						</div>
					</div>
				</div> <!--//termina dados do fornecedor-->
				
				<div class="panel panel-default">
					<div class="panel-body">
					<h3>Endereco</h3>
						<div class="form-group">
							<?php echo $this->Form->input('Fornecedore.endereco_id', array('type' => 'hidden', 'class' => 'form-control', 'placeholder' => 'endereco_id'));?>
						</div>
						<div class="row">
							<div class="form-group col-md-10">
								<?php echo $this->Form->input('Endereco.rua', array('class' => 'form-control', 'placeholder' => 'Enderecos Id'));?>
							</div>
							<div class="form-group col-md-2">
								<?php echo $this->Form->input('Endereco.numero', array('class' => 'form-control', 'placeholder' => 'Representante'));?>
							</div>
						</div>
						<div class="row">
							<div class="form-group col-md-9">
								<?php echo $this->Form->input('Endereco.bairro', array('class' => 'form-control', 'placeholder' => 'Representante'));?>
							</div>
							<div class="form-group col-md-3">
								<?php echo $this->Form->input('Endereco.cep', array('class' => 'form-control', 'placeholder' => 'Representante'));?>
							</div>
						</div>
						<div class="row">
							<div class="form-group col-md-6">
								<?php echo $this->Form->input('Endereco.complemento', array('class' => 'form-control', 'placeholder' => 'Representante'));?>
							</div>
							<div class="form-group col-md-6">
								<?php echo $this->Form->input('Endereco.cidade_id', array('class' => 'form-control', 'placeholder' => 'Representante'));?>
							</div>
						</div>
					</div>
				</div>
				
				<div class="form-group">
					<?php echo $this->Form->submit(__('Submit'), array('class' => 'btn btn-default')); ?>
				</div>

			<?php echo $this->Form->end() ?>

		</div><!-- end col md 12 -->
	</div><!-- end row -->
</div>
